import time

from selenium.webdriver.common.by import By

from common.Untils import QESDriver

class MyProject:
    url = ""
    driver = ""
    def __init__(self):
        self.url = "http://8.155.1.153:8081/project"
        self.driver = QESDriver.driver
        self.driver.get(self.url)


    def GetMyProject(self):
        # 列展示
        self.driver.find_element(By.XPATH,'//*[@id="sk-layout"]/div/div/section/div[2]/main/div/div[1]/div[2]/div/div/div/div/div/div/div/div/label[2]').click()
        time.sleep(0.5)
        QESDriver.GetScreenShot()
        # 平铺展示
        self.driver.find_element(By.XPATH,'//*[@id="sk-layout"]/div/div/section/div[2]/main/div/div[1]/div[2]/div/div/div/div/div/div/div/div/label[1]').click()
        time.sleep(0.5)
        QESDriver.GetScreenShot()
        # 新建项目
        self.driver.find_element(By.XPATH,'//*[@id="sk-layout"]/div/div/section/div[2]/main/div/div[1]/div[1]/span/div/div/button').click()
        QESDriver.GetScreenShot()
        # self.driver.find_element(By.XPATH,'/html/body/div[4]/div/div/ul/li[1]/span').click()

